<div class="zs-body" data-ng-init="formInit('gzwlkyxmlfry', {
        keyField:'id',
        randomFields:['id'],
        orderObject:{id:0}
    }) && loadData('gzwlkyxmlfry');setConHei();">
    <div class="zs-map-tool">
        <div class="location">
            <a href="javascript:;">首页</a>
            <i class="right-arr"></i>
            <a href="javascript:;">项目管理</a>
            <i class="right-arr"></i>
            <a href="javascript:;">外来科研项目人随访人员</a>
        </div>
        <div class="option">
            <input type="button" class="zs-btn orange" value="新建" 
                ng-click="addRow('gzwlkyxmlfry') && openWindow('edit');"/>
            <input type="button" class="zs-btn orange" value="编辑" 
                ng-click="editRow('gzwlkyxmlfry', gzwlkyxmlfry.sRows[0]) && openWindow('edit')"/>
            <input type="button" class="zs-btn orange" value="删除 "
                ng-click="delEntitys('gzwlkyxmlfry')"/>
        </div>
    </div>
    <div class="zs-content" style="position:unset">
        <div class="zs-nice-tab idTabs">
			<div class="tool item" style="margin-left:6px;">
            	<!--<span class="search-warpper">
                    <i class="icon"></i>
                    <input type="text" class="zs-input" placeholder="ID" ng-model="gzwlkyxmlfry.queryObject['id']"/>
                </span>-->
            	<span class="search-warpper">
                    <i class="icon"></i>
                    <input type="text" class="zs-input" placeholder="姓名" ng-model="gzwlkyxmlfry.queryObject['xingming']"/>
                </span>
				<span class="search-warpper" style="width: 65px;">负责部门
				</span>
				<span class="search-warpper">
				   <ag-Combobox class="zs-input" style="width:175px;height: 28px" 
				   		fn='dptidEdit'
				   		para="{ uDictionary:true,
				   				dictionary:'p_department',
				   				pidField:'pid',
				   				leafField:'leaf'}"
				   		ng-model="gzwlkyxmlfry.queryObject['fzbm:=']"/>
				</span>
				<span class="search-warpper" style="width: 65px;">起止时间
				  </span>
				<span class="search-warpper"  style="width: 160px;">
				    <ag-Datebox showcurday="true" addDays="start"
				 		class="zs-input" style="width:155px;height: 28px"
				 		ng-model="gzwlkyxmlfry.queryObject['lfsjjssj:>=']" >
						</ag-Datebox>
				</span>-
				 <span class="search-warpper"  style="width: 160px;">
				    <ag-Datebox showcurday="true"
				 		class="zs-input" style="width:155px;height: 28px"
				 		ng-model="gzwlkyxmlfry.queryObject['lfsjjssj:<=']" >
						</ag-Datebox>
				 </span>
            	<!--<span class="search-warpper">
                    <i class="icon"></i>
                    <input type="text" class="zs-input" placeholder="身份证号" ng-model="gzwlkyxmlfry.queryObject['shenfzh']"/>
                </span>
            	<span class="search-warpper">
                    <i class="icon"></i>
                    <input type="text" class="zs-input" placeholder="联系方式" ng-model="gzwlkyxmlfry.queryObject['lxfs']"/>
               </span>-->
            </div>
            <div class="operation item" style="margin-top:7px;">
            	<input type="button" class="zs-btn orange" value="查询" 
            		ng-click="loadData('gzwlkyxmlfry')"/>
                <!--<a class="ope-1" ng-click="loadData('gzwlkyxmlfry')"></a>
                <a class="ope-2"></a>-->
            </div>
            <div class="switch">
                
            </div>
        </div>
        <div class="date-container">
            <div id="zpgwd">
                <div class="zs-data-table">
                    <div class="container">
                        <table>
                            <thead>
                                <tr>
                                    <th>
                                        <input id="allCheckbox" type="checkbox"
                                            ng-click="selectAll('gzwlkyxmlfry','allCheckbox');" />
                                    </th>
									<!--<th>ID</th>-->
									<th>姓名</th>
									<th>性别</th>
									<th>身份证号</th>
									<th>联系方式</th>
									<th>项目负责人</th>
									<th>来访时间</th>
                                </tr>
                            </thead>
                            <tbody>
                                <tr ng-repeat="r in gzwlkyxmlfry.datas">
                                    <td>
                                        <input type="checkbox"
                                            ng-click="selectRow('gzwlkyxmlfry',r);"
                                            ng-model="r.selected" />
                                    </td>
									<!--  ID -->
            						<!--<td>
                                        <a ng-click="editRow('gzwlkyxmlfry',r) && openWindow('edit');">
                                            <label ng-bind="r.id"></label>
                                        </a>
                                   </td>-->
									<!--  姓名 -->
            						<td>
                                        <a ng-click="editRow('gzwlkyxmlfry',r) && openWindow('edit');">
                                            <label ng-bind="r.xingming"></label>
                                        </a>
                                   </td>
									<!--  性别 -->
            						<td>
                                        <a ng-click="editRow('gzwlkyxmlfry',r) && openWindow('edit');">
                                            <label ng-bind="r.xingbieName"></label>
                                        </a>
                                   </td>
									<!--  身份证号 -->
            						<td>
                                        <a ng-click="editRow('gzwlkyxmlfry',r) && openWindow('edit');">
                                            <label ng-bind="r.shenfzh"></label>
                                        </a>
                                   </td>
									<!--  联系方式 -->
            						<td>
                                        <a ng-click="editRow('gzwlkyxmlfry',r) && openWindow('edit');">
                                            <label ng-bind="r.lxfs"></label>
                                        </a>
                                   </td>
								   <td>
								        <a ng-click="editRow('gzwlkyxmlfry',r) && openWindow('edit');">
								            <label>{{r.fzr}}({{r.fzbmName}})</label>
								        </a>
								   </td>
								   <td>
								        <a ng-click="editRow('gzwlkyxmlfry',r) && openWindow('edit');">
								            <label>
												<b>开始:</b>{{r.lfsj | asDate | date:'yyyy-MM-dd'}}&nbsp;
												<b>结束:</b>{{r.lfsjjssj | asDate | date:'yyyy-MM-dd'}}
											</label>
								        </a>
								   </td>
                                </tr>
                            </tbody>
                        </table>
                    </div>
                </div>
                <div class="zs-pagination-box">
                    <ag-Page fn='gzwlkyxmlfry'></ag-Page>
                </div>
            </div>
        </div>

        <div ag-Window id="edit" title="外来科研项目人随访人员编辑" width='560px' height='286px'>
            <div class="zs-form-tab ibox">
                <form name="form" novalidate>
                    <table width="100%">
                        <tbody>
          					<!--<tr>
                                <td class="text" width="20%">ID</td>
                                <td class="left" width="30%">
                                	<input type="text" ng-model="gzwlkyxmlfry.editRow.id" class="zs-input" />
                                </td>
                            </tr>-->
                            <tr>
                                <td class="text" width="20%"><font color="red">*</font>项目名称</td>
                                <td class="left" width="30%">
                                	<input readonly="true" ng-model="gzwlkyxmlfry.editRow.sxmmc" class="zs-input" />
                                	
                                	 <span ng-show="false"><input hide-novalidate="true" 
                                		alias="项目名称" required 
                                		ng-model="gzwlkyxmlfry.editRow.sxmmc"
                                		name="form_sxmmc"/></span>
                                </td>
                                <td class="left" width="50%" colspan="2">
                                	<input type="button" name="ok" value="选择项目" class="zs-btn c-green" 
                                        ng-click="openWindow('chooseProject');" />
                                    <input type="button" name="ok" value="查看项目" class="zs-btn c-green" 
                                        ng-click="toQueryWork('wlkyxmsqb.html','wlkyxmrqxk','gzwlkyxmsqb','gzwlkyxmsqb',gzwlkyxmlfry.editRow.xmid);" />
                                </td>
                            </tr>
          					<tr>
                                <td class="text" width="20%"><font color="red">*</font>姓名</td>
                                <td class="left" width="30%">
                                	<input type="text" ng-model="gzwlkyxmlfry.editRow.xingming" class="zs-input" />
                                	
                                	   
                                        <span ng-show="false"><input hide-novalidate="true" 
                                		alias="姓名" required 
                                		ng-model="gzwlkyxmlfry.editRow.xingming"
                                		name="form_xingming"/></span>
                                </td>
     
                                <td class="text" width="20%"><font color="red">*</font>性别</td>
                                <td class="left" width="30%"><span>
                                	<ag-Combobox style="width:175px;height:28px;"
                                        para="{	uDictionary:true,
                                        		editable:true,
                                        		dictionary:'p_sex'}"
                                        ng-model="gzwlkyxmlfry.editRow.xingbie"
                                        text-Value="gzwlkyxmlfry.editRow.xingbieName" required/>
                                        </span>
                                        
                                        <span ng-show="false"><input hide-novalidate="true" 
                                		alias="性别" required 
                                		ng-model="gzwlkyxmlfry.editRow.xingbie"
                                		name="form_xingbie"/></span>
                                	<!--<input type="text" ng-model="gzwlkyxmlfry.editRow.xingbie" class="zs-input" />-->
                                </td>
                            </tr>
          					<tr>
                                <td class="text" width="20%"><font color="red">*</font>身份证号</td>
                                <td class="left" width="30%">
                                	<input type="text" ng-model="gzwlkyxmlfry.editRow.shenfzh" class="zs-input" />
                                	
                                	<span ng-show="false"><input hide-novalidate="true" 
                                		alias="身份证号" required 
                                		ng-model="gzwlkyxmlfry.editRow.shenfzh"
                                		name="form_shenfzh"/></span>
                                </td>
                          
                                <td class="text" width="20%"><font color="red">*</font>联系方式</td>
                                <td class="left" width="30%">
                                	<input type="text" ng-model="gzwlkyxmlfry.editRow.lxfs" class="zs-input" />
                                	
                                	<span ng-show="false"><input hide-novalidate="true" 
                                		alias="联系方式" required 
                                		ng-model="gzwlkyxmlfry.editRow.lxfs"
                                		name="form_lxfs"/></span>
                                </td>
                            </tr>
							<tr ng-show="gzwlkyxmlfry.editRow.xmid">
							    <td class="text" width="20%">项目负责部门:</td>
							    <td class="left" width="30%">
							    	<label ng-bind="gzwlkyxmlfry.editRow.fzbmName"></label>
							    </td>
							    <td class="text" width="20%">项目负责人:</td>
							    <td class="left" width="30%">
							    	<label ng-bind="gzwlkyxmlfry.editRow.fzr"></label>
							    </td>
							</tr>
							<tr ng-show="gzwlkyxmlfry.editRow.xmid">
							    <td class="text" width="20%">来访开始时间:</td>
							    <td class="left" width="30%">
							    	<label ng-bind="gzwlkyxmlfry.editRow.lfsj | asDate | date:'yyyy-MM-dd'"></label>
							    </td>
							    <td class="text" width="20%">来访结束时间:</td>
							    <td class="left" width="30%">
							    	<label ng-bind="gzwlkyxmlfry.editRow.lfsjjssj | asDate | date:'yyyy-MM-dd'"></label>
							    </td>
							</tr>
                        </tbody>
                        <tfoot>
                            <tr>
                                <td colspan="4">
                                    <input type="button" name="ok" value="保存" class="zs-btn c-red"
                                        ng-click="formValidate(form) && save('gzwlkyxmlfry', gzwlkyxmlfry.editRow, closeWindow('edit'))"/>
                                    <input type="button" name="ok" value="取消" class="zs-btn c-green" 
                                        ng-click="closeWindow('edit')" />
                                </td>
                            </tr>
                        </tfoot>
                    </table>
                </form>
            </div>
        </div>
        <div ag-Window id="chooseProject" title="选择项目" width='560px' height='360px'>
		    <div class="zs-form-tab ibox"
		    	data-ng-init="formInit('gzwlkyxmsqb', {
			        keyField:'id',
			        randomFields:['id'],
			        orderObject:{id:0}
			    }) && loadData('gzwlkyxmsqb');setConHei();">
		        <div class="zs-nice-tab idTabs">
					<div class="tool item" style="margin-left:6px;">
		            	<span class="search-warpper">
		                    <i class="icon"></i>
		                    <input type="text" class="zs-input" placeholder="项目名称" ng-model="gzwlkyxmsqb.queryObject['sxmmc:like']"/>
		                </span>
		            	<span class="search-warpper">
		                    <i class="icon"></i>
		                    <input type="text" class="zs-input" placeholder="项目类型" ng-model="gzwlkyxmsqb.queryObject['sxmlx:like']"/>
		                </span>
		            </div>
		            <div class="operation item">
		                
		                <input type="button" class="zs-btn orange" value="查询 "
	                			ng-click="loadData('gzwlkyxmsqb')"/>
		            </div>
		            <div class="switch">
		                
		            </div>
		        </div>
		        <div class="date-container">
		            <div id="zpgwd">
		                <div class="zs-data-table">
		                    <div class="container">
		                        <table>
		                            <thead>
		                                <tr>
		                                	<th></th>
											<th>项目名称</th>
											<th>申请编号</th>
											<th>项目负责人</th>
		                                </tr>
		                            </thead>
		                            <tbody>
		                                <tr ng-repeat="r in gzwlkyxmsqb.datas">
		                                	<td>
		                                        <input type="checkbox"
		                                            ng-click="selectRow('gzwlkyxmsqb',r);"
		                                            ng-model="r.selected" />
		                                    </td>
											<!--  项目名称 -->
		            						<td>
		                                        <a ng-click="chooseProject(gzwlkyxmlfry.editRow,r,'chooseProject');">
		                                            <label ng-bind="r.xmmc"></label>
		                                        </a>
		                                   </td>
		                                   <!--  申请编号 -->
		            						<td>
		                                        <a ng-click="chooseProject(gzwlkyxmlfry.editRow,r,'chooseProject');">
		                                            <label ng-bind="r.bh"></label>
		                                        </a>
		                                   </td>
											<!--  负责人 -->
		            						<td>
		                                        <a ng-click="chooseProject(gzwlkyxmlfry.editRow,r,'chooseProject');">
		                                            <label ng-bind="r.fzr"></label>
		                                        </a>
		                                   </td>
		                                </tr>
		                            </tbody>
		                        </table>
		                    </div>
		                </div>
		                <div class="zs-pagination-box">
		                    <ag-Page fn='gzwlkyxmsqb'></ag-Page>
		                </div>
		                <div style="text-align: center;" >
			                <input type="button" class="zs-btn orange" value="选择 "
	                			ng-click="chooseProject(gzwlkyxmlfry.editRow,gzwlkyxmsqb.sRows[0],'chooseProject','gzwlkyxmsqb');"/>
			            </div>
		            </div>
		        </div>
		    </div>
		</div>
    </div>
</div>